import request from '@/utils/request';

// 用户登录
export function signIn(params) {
	return request({
		url: `/user/login/${params.userName}/${params.password}/${params.code}`,
		method: 'post',
	});
}

// 用户退出登录
export function signOut(params) {
	return request({
		url: '/user/signOut',
		method: 'post',
		data: params,
	});
}

// 获取验证码
export function getCode() {
	return request({
		url: `/user/image`,
		method: 'get',
		responseType: 'blob'
	})
}

// 游客登录
export function visitorsLogin() {
	return request({
		url: `/user/youkelogin`,
		method: 'post'
	})
}
